<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta name="keywords" content="" />
<meta name="description" content="" />
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>Daftar Proyek</title>

<link rel="stylesheet" type="text/css" href="<?php echo base_url() ?>css/style.css" media="all" title="Default" />
<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="rss/" />

<link href="style.css" rel="stylesheet" type="text/css" media="screen" />
</head>

<body>
<div id="wrapper">
	
	<div id="page">
		<div id="page-bgtop">
			<div id="page-bgbtm">
				<div id="content">
					<div class="post">
						<h2 class="title"><a href="#">Daftar Proyek</a></h2>
					  <div style="clear: both;">&nbsp;</div>
						<div class="entry">
							<p><a href=""><strong>Daftar Proyek Anda</strong></a></p>
					    <div>
                        <?php echo form_open('lihat_proyek/display/'); ?>						       
							  <form method="post" action="">
							    
							    <table width="634" border="0">
                                  <tr>
                                    <td width="170">Cari Berdasarkan</td>
                                    <td width="161"><select name="id_status" id="select">
									 <option value=0 <?php if($id_status == 0) echo 'selected="selected"';?> >All</option>
									<?php foreach($status_proyek->result() as $sta_pro){
										$id = $sta_pro->id_status_proyek;
										$status = $sta_pro->status_proyek;				
									?>
                                      <option <?php if($id_status == $id) echo 'selected="selected"';?> value=<?php echo$id;?>><?php echo $status;?></option>
                                      <?php }?>
                                    </select>
                                    </td>
                                    <td width="36">&nbsp;</td>
                                    <td width="249"><input name="submit2" type="submit" id="search-submit2" value="GO" /></td>
                                  </tr>
                                </table>
							    <p>&nbsp;</p>
							    <table id="box-table-a" summary=" " border=1>
                                  <thead>
                                    <tr>
                                      <th scope="col">No</th>
                                      <th scope="col">Nama Proyek</th>
                                      <th scope="col">Tanggal Pembuatan</th>
									  <th scope="col">Jumlah Worker/Target Worker</th>
									  <th scope="col">Perlu Review</th>
									  <th scope="col">Status Proyek</th>
									  <th scope="col">Detail</th>
									  <th scope="col">Lihat Hasil Worker</th>
                                    </tr>
                                  </thead>							 
                                  <tbody>
				<?php 
				
					$c=1;		
				
				foreach($proyek as $pro){
					$id_proyek = $pro->id_proyek;	
					$judul_proyek = $pro->judul_proyek;
					$gaji_proyek = $pro->gaji_proyek;				
					$jumlah_pekerja= $pro->jumlah_pekerja;
					$petunjuk_pengerjaan = $pro->petunjuk_pengerjaan; 
					$bukti_pengerjaan = $pro->bukti_pengerjaan;
					$status_proyek = $pro->status_proyek;
					$sub_kategori_proyek = $pro->sub_kategori_proyek;
					$attachment_petunjuk = $pro->attachment_petunjuk;
					$tanggal_pembuatan_proyek = $pro->tanggal_pembuatan_proyek;
					$total_biaya_proyek = $pro->total_biaya_proyek;
					$working_worker = $pro->working_worker->hasil_kerja;
					$unreviewed_work = $pro->unreviewed_work->hasil_kerja;
					
				?>
									 <tr>
									  <td><div align="center" ><?php echo $c."."; ?></div></td>
									  <td><div align="center" ><?php echo $judul_proyek; ?></div></td>
									  <td><div align="center" ><?php echo $tanggal_pembuatan_proyek; ?></div></td>
									  <td><div align="center" ><?php echo $working_worker.'/'.$jumlah_pekerja; ?></div></td>
									  <td><div align="center" ><?php echo $unreviewed_work; ?></div></td>
									  <td><div align="center" ><?php echo $status_proyek; ?></div></td>
									  <td><div align="center" ><a href='<?php echo site_url('lihat_proyek/detail_proyek/'.$id_proyek);?>'>Detail</a></div></td>
									  <td><div align="center" ><a href='<?php echo site_url('manajemen_pekerjaan_worker/display/'.$id_proyek);?>'>Lihat</a></div></td>
									 </tr>
									
									<?php
				echo form_close();
			  	$c++;
				}
			  ?>
                                  </tbody>
								  
                                </table>
                                <p class="links"><?php echo  $this->pagination->create_links(); ?></p>
							  </form>
							  
						  </div>
						  
					  </div>
					</div>
				  
					<div class="post"></div>
					<div style="clear: both;">&nbsp;</div>
				</div>
				<!-- end #content -->
							
			</div>
		</div>
	</div>
	<!-- end #page -->
</div>
<div id="footer">
	<p>Copyright (c) 2010  All rights reserved. Design by <a href="http://www.freecsstemplates.org/">Mikrobis Team</a>.</p>
</div>
<!-- end #footer -->
</body>
</html>
